<div class="modal fade" id="alertBox" tabindex="-1" role="dialog" aria-labelledby="alert" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <h4 class="modal-title" id="alertBoxLabel"></h4>
            </div>
            <div class="modal-body" id="alertBoxContent">

            </div>
            <div class="modal-footer">
                <input type="button" class="btn btn-primary" data-dismiss="modal" value="ОК">
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">
	function alertBox(message, title) {
		if (title == undefined) title = '';

		$('#alertBoxLabel').html(title);
		$('#alertBoxContent').html(message);
		$('#alertBox').modal('show');
	}

	$(function(){
		$(document).on('hidden.bs.modal', '.modal', function () {
			$(this).removeData('bs.modal');
		});

	});
</script>